<%@page import="java.awt.print.Printable"%>
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<html>
<head>
<title>_新增托盘</title>
<script type="text/javascript">
	$(document).ready(function() {
		//聚焦第一个输入框
		$("#ame").focus();
		//为inputForm注册validate函数
		$("#inputForm").validate();
	});
</script>
</head>

<body>
	<section class="content">
		<div class="row">
			<div class="col-md-12">

				<!-- Primary box -->
				<div class="box box-solid box-primary">
					<div class="box-header">
						<i class="fa fa-edit"></i>
						<h3 class="box-title">新增托盘</h3>
						<div class="box-tools pull-right">
							<button class="btn btn-primary btn-sm" data-widget="collapse">
								<i class="fa fa-minus"></i>
							</button>
						</div>
					</div>
					<div class="box-body">
						<form id="inputForm" action="${ctx}/v2_pallet/${action}"
							method="post" class="form-horizontal">
							<fieldset>
								<div class="form-group">
									<label class="col-sm-3 control-label">托盘名称:</label>
									<div class="col-sm-6">
										<input type="text" id="name" name="name" value=""
											class="form-control input-large required" minlength="2" />
									</div>
								</div>
								<div class="form-group">
									<label class="col-sm-3 control-label">仓库:</label>
									<div class="col-sm-6">
										<select name="warehouseCode" id="warehouseCode"
											style="width: 157px;" class="form-control input-large required">
											<option value=""></option>
											<c:forEach items="${warehouseList}" var="wm">
												<option value="${wm.groupCode}">${wm.groupName}</option>
											</c:forEach>
										</select>
									</div>
								</div>
								<div class="form-group">
									<label class="col-sm-3 control-label">起始值:</label>
									<div class="col-sm-6">
										<input type="text" id="palletNum" name="palletNum" value=""
											class="form-control input-large digits required" minlength="1" maxlength="5"/>
									</div>
								</div>
								<div class="form-group">
									<label class="col-sm-3 control-label">数量:</label>
									<div class="col-sm-6">
										<input type="text" id="num" name="num" value=""
											class="form-control input-large digits required" minlength="1" maxlength="3" min="1"/>
									</div>
								</div>
								<div class="form-group">
									<label class="col-sm-3 control-label">LPN:</label>
									<div class="col-sm-6">
										<input type="text" value="系统自动分配，规则为：仓库代码+序号"
											class="form-control input-large required" minlength="2"
											readonly="readonly" />
									</div>
								</div>
								<div class="form-group">
									<label class="col-sm-3 control-label">编码:</label>
									<div class="col-sm-6">
										<input type="text" value="系统根据仓库自动生成"
											class="form-control input-large required" minlength="2"
											readonly="readonly" />
									</div>
								</div>
								<div class="modal-footer bg-gray">
									<input id="submit_btn" class="btn btn-primary" type="submit"
										value="提交" />&nbsp; <input id="cancel_btn" class="btn"
										type="button" value="返回" onclick="history.back()" />
								</div>
							</fieldset>
						</form>
					</div>
				</div>
			</div>
		</div>
	</section>

</body>
</html>
